package org.naive.vstream.render;

public class SubpixelRenderState extends RendererState {
	private static final int MAX_DIM = 1024;

	private double aggregate;

	public SubpixelRenderState() {
		super(0, 0, MAX_DIM, MAX_DIM);
	}

	@Override
	protected void fill(int x, int y, int w, int h, int b) {
		aggregate += w * h * b;
	}

	public int getBrightess() {
		return (int) (aggregate / (MAX_DIM * MAX_DIM));
	}
}
